<template>
    <view :style="themeColor">
        <view class="page" >
    <view class="flex flex-wrap align-center justify-between benben-position-layout flex concernMy_flex_0"    :style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }">
            <view   class='flex flex-wrap align-center concernMy_fd0_0'   @tap.stop="handleJumpDiy" data-type="back" data-url="1"   >
        <image class='concernMy_fd0_0_c0'  mode="aspectFit"  :src='STATIC_URL+"234.png"'></image>
</view>
<text class='concernMy_fd0_1'  >{{$t('我的关注')}}</text>
    <view   class='flex flex-wrap align-center concernMy_fd0_0'      >
        </view>

        </view>
<view :style="{height: (88+StatusBarRpx)+'rpx'}"  ></view>
<!---关注flex布局开始-->
 <view class="flex flex-direction align-stretch benben-flex-layout concernMy_flex_1"    >
            <template v-for = '(item,key0) in dataList'>
    <view   class='flex align-center concernMy_fd1_0'       :key='key0'>
        <image class='concernMy_fd1_0_c0'  mode="aspectFill"  :src='item.store_logo'></image>
    <view   class='flex flex-direction align-stretch flex-sub'      >
            <view   class='flex flex-wrap align-center'      >
        <text class='flex-sub concernMy_fd1_0_c1_c0_c0'  >{{item.store_name}}</text>
</view>
    <view   class='flex flex-wrap align-center concernMy_fd1_0_c1_c1'      >
        <text class='concernMy_fd1_0_c1_c1_c0'  >{{$t('销量')}}</text>
<text class='concernMy_fd1_0_c1_c1_c0'  >{{item.sales}}</text>
</view>
    <view   class='flex flex-wrap align-center'      >
        <text class='concernMy_fd1_0_c1_c2_c0'  >{{item.follow_num}}</text>
<text class='concernMy_fd1_0_c1_c2_c0'  >{{$t('人关注')}}</text>
</view>
</view>
<button class='concernMy_fd1_0_c2'  @tap.stop="CancelFollowFunc(item.store_id)"  >{{$t('取消关注')}}</button>
</view>
    </template>
    <fu-empty :pagingListLoadedAll="pagingListLoadedAll" :pagingListNoListData="pagingListNoListData" :listDataLength="listDataLength" :isLoadInit="isLoadInit"></fu-empty>
</view>
        
<!---关注flex布局结束-->
    
    
        </view>
    </view>
</template>
<script>
    import pagingList from '@/common/mixin/paging_list.js';
import {validate} from '@/common/utils/validate.js'
    
    export default {
        components:{},
        mixins: [pagingList],
        
        data(){
			return {"minixPagingListsApi":"","pageingListApiMethod":"","allowOnloadGetList":false,"dataList":[],"dataMessage":[]};
		},
		computed:{
            themeColor() {
              return this.$store.getters.themeColor
            },
            
		},
		watch:{},
		onLoad(options){
            
		},
        onUnload() {
                
        },
		onReady(){
            
		},
		onShow(){
            this.getListFunc()
		},
		onHide(){
            
		},
		onResize(){
            
		},
		onPullDownRefresh(){
            this.getListFunc()
		},
		onReachBottom(e){
            
		},
		onPageScroll(e){
            
		},
		methods:{
                            //取消关注
                async CancelFollowFunc(id){
                        //请求方法
    //数据验证
    
  let datadataMessage = await this.$api.post(global.apiUrls.post637ca2333f0be, {
    shop_id:id
  });
  
  if (datadataMessage.data.code != 1) {
    this.$message.info(datadataMessage.data.msg);
    return
  } 
  let infodataMessage = datadataMessage.data;
  this.dataMessage = infodataMessage.data
  
                    uni.showToast({
                        title:global.i18n.t('取消成功'),
                        mask:true,
                        icon:'none',
                        duration: 1500
                    });
                    this.getListFunc()
                },
                //用户管理-关注列表
                 getListFunc(){
                                    this.minixPagingListsApi = global.apiUrls.post637c9f95780cb;
                this.pageingListApiMethod = 'get';
                this.allowOnloadGetList = false;
                this.pagingListPostDataContent = {sort_type:'desc'}
                this.listData = [];
                this.dataList = this.listData;
                this.pagingListToggle();
                
                },
                pagingListPostData(){
                    return this.pagingListPostDataContent
                }
		}
    };
</script> 
<style lang="scss" scoped>
           .page{
            width: 100vw;
            overflow-x: hidden;
            min-height: calc(100vh - var(--window-bottom));
            background:var(--benbenbgColor1);background-size: 100% auto;
        }
    .concernMy_flex_0{
        background:#fff;width:750rpx;height:88rpx;overflow:hidden;z-index:10;top:0rpx;background-size:100% auto !important;
    }
    .concernMy_fd0_1{
        color:#333333;font-size:36rpx;font-weight:500;line-height:50rpx;
    }
    .concernMy_fd0_0_c0{
        width:20rpx;height:36rpx;border-radius:0rpx 0rpx 0rpx 0rpx;margin:0rpx 0rpx 0rpx 32rpx;
    }
    .concernMy_fd0_0{
        width:100rpx;height:88rpx;
    }
    .concernMy_flex_1{
        background:#fff;padding:0rpx 24rpx 8rpx 24rpx;background-size:100% auto !important;
    }
    .concernMy_fd1_0_c2{
        border:1px solid var(--benbenbdColor0);background:var(--benbenbgColor1);border-radius:36rpx 36rpx 36rpx 36rpx;font-size:24rpx;color:var(--benbenFontColor5);width:156rpx;height:56rpx;line-height:56rpx;
    }
    .concernMy_fd1_0_c1_c2_c0{
        color:#999999;font-size:24rpx;font-weight:400;line-height:33rpx;
    }
    .concernMy_fd1_0_c1_c1_c0{
        color:#666666;font-size:24rpx;font-weight:400;line-height:33rpx;
    }
    .concernMy_fd1_0_c1_c1{
        margin:30rpx 0rpx 24rpx 0rpx;
    }
    .concernMy_fd1_0_c1_c0_c0{
        color:#333333;font-size:28rpx;font-weight:500;line-height:40rpx;-webkit-line-clamp:1;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-box-orient:vertical;
    }
    .concernMy_fd1_0_c0{
        width:160rpx;height:160rpx;margin:0rpx 24rpx 0rpx 0rpx;border-radius:16rpx 16rpx 16rpx 16rpx;
    }
    .concernMy_fd1_0{
        border-bottom:1px solid #eee;padding:20rpx 0rpx 24rpx 0rpx;
    }
</style>